import http from "@/api";

/**
 * @name //门禁管理
 */

// 获取门禁列表
export const getDoorList = (params = {}) => {
  return http.post(`/door/query`, params, { noLoading: true });
};

// 获取已授权员工列表
export const getAuthEmployeeList = (params = {}) => {
  return http.post(`/rule/employee/rule/query`, params, { noLoading: true });
};

export const getEmployeeList = (params = {}) => {
  return http.post(`/rule/employee/door/query`, params, { noLoading: true });
};

// 获取员工卡类型选择列表
export const getEmpcardTypes = (params = {}) => {
  return http.get(`/lookup/empcard/types`, params, { noLoading: true });
};

// 增加授权门禁
export const addAccess = (params = {}) => {
  return http.post(`/rule/employee/access/add`, params);
};

// 删除已授权门禁
export const delAccess = (params = {}) => {
  return http.post(`/rule/employee/access/delete`, params);
};

// 复制门禁点权限
export const copyDoorAccess = (params = {}) => {
  return http.post(`/rule/door/access/copy`, params);
};

// 获取区域选择列表
export const getAreaSelList = (params = {}) => {
  return http.get(`/lookup/areas`, params, { noLoading: true });
};
